home *** CD-ROM | disk | FTP | other *** search
/ Aminet 31 / Aminet 31 (1999)(Schatztruhe)[!][Jun 1999].iso / Aminet / util / libs / chunky_dev.lha / chunky_dev / Demos / _shared / requester.c < prev    next >
Encoding:
C/C++ Source or Header  |  1999-03-15  |  703 b   |  37 lines

  1. //
  2. // chunky.library demo
  3. // MODULE: shows an EasyRequest() requester on our DemoScreen
  4. //
  5. // (c) 1999 Rosande Limited, all rights reserved.
  6. // PUBLIC DOMAIN
  7. //
  8.  
  9. #include <exec/types.h>
  10. #include <intuition/intuition.h>
  11. #include <pragma/intuition_lib.h>
  12. #include <stdarg.h>
  13.  
  14. #include "screen.h"
  15.  
  16. BOOL DEMO_Request(STRPTR Body, STRPTR Gadgets, ...)
  17. {
  18.   va_list myargs;
  19.   struct EasyStruct myes =
  20.   {
  21.     sizeof(struct EasyStruct),
  22.     0,
  23.     "chunky.library Demo Request",
  24.     Body,
  25.     Gadgets,
  26.   };
  27.   BOOL Result;
  28.  
  29.   if(Gadgets == NULL) myes.es_GadgetFormat = "Okay";
  30.  
  31.   va_start(myargs, Gadgets);
  32.   Result = EasyRequestArgs(DemoWindow, &myes, 0, (void *)myargs);
  33.   va_end(myargs);
  34.  
  35.   return(Result);
  36. }
  37.